/* ==================================================================   
 * Created [2009-4-27 下午11:32:55] by Jon.King 
 * ==================================================================  
 * TSS 
 * ================================================================== 
 * mailTo:jinpujun@hotmail.com
 * Copyright (c) Jon.King, 2009-2012 
 * ================================================================== 
 */

package com.jinhe.tss.cms.entity;

import java.util.HashMap;
import java.util.Map;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

import com.jinhe.tss.core.persistence.IEntity;
import com.jinhe.tss.core.util.BeanUtil;
import com.jinhe.tss.core.web.dispaly.xform.IXForm;

/** 
 * 敏感词汇过滤类
 */
@Entity
@Table(name = "cms_wordsfilter")
public class WordsFilter implements IEntity, IXForm {

    @Id
    private Long id;                // 站点Id
    
    @Column(length = 4000)
    private String shieldWords;        // 文章屏蔽的词汇
    
    @Column(length = 4000)
    private String forbidWords;       // 文章禁止的词汇
 
    public WordsFilter(){
    }
    
    public WordsFilter(Long siteId, String shieldWords, String forbidWords){
        this.id = siteId;
        this.shieldWords = shieldWords;
        this.forbidWords = forbidWords;
    }
 
    public String getShieldWords() {
        return shieldWords;
    }
 
    public void setShieldWords(String shieldWords) {
        this.shieldWords = shieldWords;
    }
 
    public String getForbidWords() {
        return forbidWords;
    }
 
    public void setForbidWords(String forbidWords) {
        this.forbidWords = forbidWords;
    }
 
    public Long getId() {
        return id;
    }
 
    public void setId(Long id) {
        this.id = id;
    }
    
    public Map<String, Object> getAttributesForXForm() {
        Map<String, Object> map = new HashMap<String, Object>();
        BeanUtil.addBeanProperties2Map(this, map);
        return map;
    }
}